<html>
<head><meta charset="utf-8"><title>adding new stdarch target · t-compiler · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/index.html">t-compiler</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/adding.20new.20stdarch.20target.html">adding new stdarch target</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="221240218"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/adding%20new%20stdarch%20target/near/221240218" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/adding.20new.20stdarch.20target.html#221240218">(Dec 30 2020 at 19:37)</a>:</h4>
<p><code>stdarch</code> and <code>core</code> seem to be in a chicken/egg  situation. what's the process with adding new arches?</p>



<a name="221241258"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/adding%20new%20stdarch%20target/near/221241258" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/adding.20new.20stdarch.20target.html#221241258">(Dec 30 2020 at 19:50)</a>:</h4>
<p>You can leave <code>stdarch</code> unchanged at first. It is only necessary when you actually want to use the vendor intrinsics of the respective arch. <code>core</code> shouldn't need any changes either as the only arch dependent things in there are workarounds for LLVM bugs I think. You only need to enable the LLVM target and add a target specification to compiler/rustc_target I think. In addition you may want to add support to various widely used crates that are arch dependent like libc and cc.</p>



<a name="221241572"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/adding%20new%20stdarch%20target/near/221241572" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/adding.20new.20stdarch.20target.html#221241572">(Dec 30 2020 at 19:54)</a>:</h4>
<p>ok, thanks!</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>